export default [
    {
        path: '/',
        redirect: '/login'
    },
    {
        path: '/404',
        component: () => import('../views/Loading.vue')
    },
    {
        path: '/login',
        component: () => import('../views/Login.vue')
    }, {
        path: '/about',
        component: () => import('../views/About.vue'),
        children: [
            {
                path: 'user',
                name: '管理员',
                meta: {
                    arr: ['系统管理', '管理员'],
                    permissions: ['admin.user.read']
                },
                component: () => import('../components/user/User.vue')
            },
            {
                path: 'role',
                name: '角色管理',
                meta: {
                    arr: ['系统管理', '角色管理'],
                    permissions: ['admin.user.read']
                },
                component: () => import('../components/user/Role.vue')
            },
            {
                path: 'category',
                name: '分类管理',
                meta: {
                    arr: ['商品管理', '分类管理'],
                    permissions: ['shop.category.read']
                },
                component: () => import('../components/user/Category.vue')
            },
            {
                path: 'product',
                name: '货品管理',
                meta: {
                    arr: [ '商品管理','货品管理'],
                    iconPath: 'el-icon-s-goods',
                    permissions: ['shop.product.read']
                },
                component: () => import('../components/user/Product.vue')
            },
            {
                path: 'sale',
                component: () => import('../components/user/Sale.vue')
            },
            {
                path: 'current',
                component: () => import('../components/user/Current.vue')
            },
            {
                path: 'history',
                component: () => import('../components/user/History.vue')
            },

            {
                path: 'shop',
                component: () => import('../components/user/Shop.vue')
            },

        ]
    }
]